<?php
/*
	f configinc.	a corrie.	v 0.5
	config file for project
*/
if(!defined('DIR_SEP')){
	define('DIR_SEP', DIRECTORY_SEPARATOR);
}

define('CHARSET', 'utf-8');
define('TIMEZONE', "Asia/Shanghai");
define('I', 'i'.DIR_SEP);
define('D', 'd'.DIR_SEP);
define('M', 'm'.DIR_SEP);
define('IDIR', APP_ROOT.I);
define('MDIR', APP_ROOT.M);
define('DDIR', APP_ROOT.D);
$host = "http://mapfang.dev";


$global['map'] = array(
	'key' => 'ABQIAAAA799xQIL4ZGe-GKt8lGJU-hQzr2RBNe3JhmzRIKdpJQ-38WERDxRKujV_ASVZGIdU6rhU5T1pcWQ4rw'
);

/* commen config */
/*$dir_i = array(
	'class' => IDIR."./class/"
	,'func' => IDIR."./func/"
	,'lib' => IDIR."./lib/"
	,'smarty' => IDIR."./smarty/"
	,'inc' => IDIR."./inc/"
	,'conf' => IDIR."./conf/"
	,'elem' => IDIR."elem/"
	,'cache' => DDIR."./cache/"
	,'samrtydata' => DDIR."./cache/smarty/"
	,'upgrade' => DDIR."./upgrade/"
);

$dir_m = array(	
	'module' => MDIR."./module/"
	,'controller' => MDIR."./controller/"
	,'templete' => MDIR."./template/"
);

$dir_d = array(
	'cache' => DDIR."./cache/"
	,'samrtydata' => DDIR."./cache/smarty/"
	,'upgrade' => DDIR."./upgrade/"
);*/

/* static config */
$global['url'] = array(
	'css' => $host."/d/style/"
	,'js' => $host."/d/js/"
	,'jquery' => $host."/d/jquery/"
	,'images' => $host."/d/image/"
	,'editor' => $host."/d/editor/"
);

$config_smarty = array(
	'compile_dir' => APP_ROOT . 'd'.DIR_SEP.'cache'.DIR_SEP.'smarty'.DIR_SEP.'template_c'.DIR_SEP
	,'cache_dir' => APP_ROOT . 'd'.DIR_SEP.'cache'.DIR_SEP.'smarty'.DIR_SEP.'cache'.DIR_SEP
	,'left_delimiter' => '{?'
	,'right_delimiter' => '?}'
	,'caching' => false
	,'force_compile' => false
	,'template_dir' => APP_ROOT . 'm'.DIR_SEP.'template'.DIR_SEP
	,'default' => 'default'
);

$config_cookie = array(
	'pre' => ''
	,'domain' => ''
	,'path' => '/' 
);

/* database config */
$config_db = array(
	 'server' => 'localhost'
	,'user' => 'root'
	,'pswd' => '321'
	,'name' => 'test'
	,'charset' => 'utf8'
	,'tablepre' => 'n_'
);

$config_load = array(
	 '$:class:db'
	,'$:class:base'
	,'$:class:model'
	,'$:class:view'
	,'$:smarty:Smarty.class'
	,'$:func:smarty.lib'
);

$config_lib = array('string','array','xml');

$config_route = array(
	'/^\/([a-zA-Z]{1,10})\/(\d+)$/' => '/index/index/type/$1/id/$2'
);
?>